#ifndef MOCHA_DETAIL_MATH_HPP_INCLUDED
#define MOCHA_DETAIL_MATH_HPP_INCLUDED

/**
 * @file Defines vector and matrix types and math functions. Most math constructs come directly from the CML.
 */

#include <cstdint>
#include <cml/cml.h>

namespace mocha {
/// Two-dimensional integer vector.
typedef cml::vector<int, cml::fixed<2> > ivec2;
typedef cml::vector<std::int8_t, cml::fixed<2> > i8vec2;
typedef cml::vector<std::int16_t, cml::fixed<2> > i16vec2;
typedef cml::vector<std::int32_t, cml::fixed<2> > i32vec2;
typedef cml::vector<std::int64_t, cml::fixed<2> > i64vec2;
/// Two-dimensional single-precision floating point vector.
typedef cml::vector<float, cml::fixed<2> > fvec2;
/// Two-dimensional double-precision floating point vector.
typedef cml::vector<double, cml::fixed<2> > dvec2;
/// Three-dimensional integer vector.
typedef cml::vector<int, cml::fixed<3> > ivec3;
/// Three-dimensional single-precision floating point vector.
typedef cml::vector<float, cml::fixed<3> > fvec3;
/// Three-dimensional double-precision floating point vector.
typedef cml::vector<double, cml::fixed<3> > dvec3;
typedef cml::matrix<int, cml::fixed<3, 3>, cml::row_basis, cml::row_major> imat33;
typedef cml::matrix<float, cml::fixed<3, 3>, cml::row_basis, cml::row_major> fmat33;
typedef cml::matrix<double, cml::fixed<3, 3>, cml::row_basis, cml::row_major> dmat33;
typedef cml::matrix<int, cml::fixed<4, 4>, cml::row_basis, cml::row_major> imat44;
/// 4x4 single-precision floating point matrix.
typedef cml::matrix<float, cml::fixed<4, 4>, cml::row_basis, cml::row_major> fmat44;
typedef cml::matrix<double, cml::fixed<4, 4>, cml::row_basis, cml::row_major> dmat44;
}

#endif

